home *** CD-ROM | disk | FTP | other *** search
/ World of Education / World of Education.iso / world_f / fdplot.zip / ELLIPSA.BAS next >
BASIC Source File  |  1991-11-04  |  486b  |  12 lines

  1. 100 REM ELLIPSOID SURFACE AREA CALCULATION
  2. 101 PI=3.141592654
  3. 105 CLS: PRINT "Ellipsoid surface area calculation":print
  4. 110 INPUT"Enter   LONG, SHORT  diameter of 'egg' (or 0,0 to exit) ";L,T
  5. 120 IF L=0 OR T=0 THEN CHAIN "MENU"
  6. 130 A=L/2:B=T/2:BE=B/A:B2=BE^2
  7. 140 IF (B/A-1.001)*(0.999-B/A)>0 THEN SA=B/A+1 ELSE SA=B/A+ATN(SQR(1/B2-1))/SQR(1-B2)
  8. 150 SA=2*PI*B*A*SA
  9. 160 PRINT: PRINT"Corresponding surface area is";SA
  10. 170 PRINT: INPUT "Press ─┘ when ready";A$
  11. 180 CHAIN "MENU"
  12.